Turn off icon cache validation by default
authorMatthias Clasen <matthiasc@src.gnome.org>
Fri, 14 Sep 2007 02:11:01 +0000 (02:11 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Fri, 14 Sep 2007 02:11:01 +0000 (02:11 +0000)
svn path=/trunk/; revision=18823

ChangeLog
gtk/gtkiconcache.c

index f0580272f4900f060180262da6dd36b40d32f602..24603fecd19f2066caee5be0bcb51ad782f8ca6e 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2007-09-13  Matthias Clasen  <mclasen@redhat.com>
+
+       * gtk/gtkiconcache.c: Turn off icon cache validation unless
+       icon theme debugging is turned on.
+
 2007-09-13  Matthias Clasen  <mclasen@redhat.com>
        
        * configure.in: Bump version to 2.12.1
index 7cce5083ae528b65c5f74f5150b2aeb7023d417a..021b64c898ef4502501ab69db3ff858c112f9b27 100644 (file)
@@ -127,14 +127,19 @@ _gtk_icon_cache_new_for_path (const gchar *path)
   info.n_directories = 0;
   info.flags = CHECK_OFFSETS|CHECK_STRINGS;
 
-  if (!_gtk_icon_cache_validate (&info))
+#ifdef G_ENABLE_DEBUG
+  if (gtk_debug_flags & GTK_DEBUG_ICONTHEME)
     {
-      g_mapped_file_free (map);
-      g_warning ("Icon cache '%s' is invalid\n", cache_filename);
+      if (!_gtk_icon_cache_validate (&info))
+        {
+          g_mapped_file_free (map);
+          g_warning ("Icon cache '%s' is invalid\n", cache_filename);
 
-      goto done;
+          goto done;
+        }
     }
-  
+#endif 
+
   GTK_NOTE (ICONTHEME, g_print ("found cache for %s\n", path));
 
   cache = g_new0 (GtkIconCache, 1);